$(function(){

	(function (doc, win) {

        var docEl = doc.documentElement,
            resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize';
        var clientWidth = '',newWidth = '',ctimer = null;
        recalc = function () {

            newWidth = $(window).width();

            clearTimeout(ctimer);

            //if(!clientWidth && newWidth < 1300) return false;

            if(newWidth === clientWidth) return false;

            clientWidth = newWidth;

            docEl.style.fontSize = 100 * (clientWidth / 750) + 'px';

            ctimer = setTimeout(function(){

            	// $(".chart-box").html('');

            	//loadingChart();

            },25)



        };

        if (!doc.addEventListener) return;

        win.addEventListener(resizeEvt, recalc, false);

        recalc();

    })(document, window);

    /**
     * 显示影片简介
     */
    $(".option-ind").on("touchstart click",function(e){

    	$(this).toggleClass("active");

    	$(".move-ind").toggle();

    	return false;

    })

    /**
     * 数据来源 提示框
     */
    
    function dataSourceTag(str){

    	str = str || '数据来源 提示框';

    	if($(".qicon-fix").length < 1){

    		return '<div class="qicon-fix">'+str+'</div>';
    	}
    }

    $(".title-qicon").on("mouseover",function(e){

    	var _x = e.pageX,_y = e.pageY,scrollTop = document.documentElement.scrollTop || document.body.scrollTop;

    	dataSourceTag();

    	$(".qicon-fix").css({"left": _x - 100 + "px","top": _y - 60 - scrollTop + "px"}).fadeIn();

    	return false;

    })

    $(".title-qicon").on("mouseleave",function(){

    	$(".qicon-fix").hide();
    })


	
})